<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>留言板内容显示</title>
</head>
<body>
<table border="1">
    <?php
    $con = mysql_connect("localhost", "root", "");
    mysql_select_db('edu', $con);
    $result = mysql_query("SELECT * FROM member");
    $list = array();
    while ($arr = mysql_fetch_assoc($result)) {
        $list[] = $arr;
    }
    ?>
    <tr>
        <th>id</th>
        <th>名字</th>
        <th>密码</th>
        <th>添加时间</th>
        <th>操作</th>
    </tr>
    <?php foreach ($list as $k) { ?>
        <tr>
            <th><?php echo $k['id'] ?></th>
            <th><?php echo $k['name'] ?></th>
            <th><?php echo $k['password'] ?></th>
            <th><?php echo date('Y-m-d H:i:s', $k['add_time']) ?></th>
            <th><a href='./update.php?id=<?php echo $k['id'] ?>'>修改</a></th>
            <th><a href='./delete.php?id=<?php echo $k['id'] ?>'>删除</a></th>
        </tr>
    <?php } ?>
</table>

<a href="index.html">返回添加页面</a>
</body>
</html>